A distributed computing environment is comprised of a group of networked computers working in concert to provide a variety of computing services. In this type of computing environment, software applications are separated into many application components. These components are distributed to server applications located on one or more networked computers, so that different components are executed by different server applications within the distributed environment. The application components are designed to effectively operate in a distributed environment. The advantage of designing applications for a distributed computing environment include increased scalability to accommodate a large numbers of users, increased reliability, and efficient use of computing resources
One example of a distributed computing environment is the Java™ 2 platform, Enterprise Edition (J2EE) architecture, which was developed by Sun Microsystems. J2EE applications are comprised of primarily of Enterprise Java™ Beans (EJB), which are self-contained, reusable application components written in the Java™ programming language. The specification for the J2EE architecture is described in Java™ 2 Platform Enterprise Edition Specification, v1.3, available at http://java.sun.com/j2ee/j2ee-1—3-pfd4-spec.pdf and incorporated by reference herein.
In the J2EE architecture, application components are executed within an application server program installed on each computer in a distributed computing environment. The application components for an application can be spread over many application servers within the distributed computing environment, or concentrated within a single application server.
The J2EE application server program provides low-level functionality needed by application components in an distributed programming environment. The functions provided by the J2EE application server program include enabling communication between the distributed application components, as well communication between different applications located within the distributed computing environment or outside this environment. The application server handles systems resources, threads, memory, database connections, security, client connectivity, and transaction management. The application server also manages the installation and removal of J2EE applications. This includes the distribution of application components to application servers in the distributed computing environment. By integrating these functions into the application server, the J2EE platform allows application developers to concentrate on implementing the business logic of the application, rather than low-level functionality required by distributed applications.
Although the J2EE application platform is designed to eliminate many of the complexities associated with developing distributed applications, software development with this programming paradigm remains complex and difficult. One of the difficulties associated with the development of J2EE applications is the problem of deployment. Deployment is the process of installing the various application components comprising an application on the application servers within a distributed computing environment. An explanation of the structure of a J2EE application is helpful in understanding the complexities associated with deploying a J2EE application.
FIG. 1 shows a typical structure of a fully packaged J2EE application. A J2EE application in this form is ready to be installed in a distributed computing environment. The packaged J2EE application is contained in an Enterprise Application Archive file (.EAR) 100. The .EAR file contains the J2EE application 107 and a J2EE application deployment descriptor (DD) 105. The J2EE application 107 contains one or more application components. These application components may be Enterprise Java™ Beans, 111, 110, and 112; J2EE client applications 120, 121, and 122; or web components, 130, 131, and 132. The deployment descriptor 105 is a file that describes the attributes of the J2EE application, such as transaction attributes or security authorizations. In an embodiment, the deployment descriptor is encoded in Extensible Markup Language (XML), a language widely used for describing information. Additional deployment descriptors may be used to describe individual components of the J2EE application.
Enterprise Java™ Beans (EJB's) are contained in a Java™ Archive (.JAR) file, as shown in detail in 110. A .JAR file bundles multiple files together in a single archive file. Typically, a .JAR file contains the Java™ class files and auxiliary resources associated with an application component. For an EJB, the .JAR file contains an EJB deployment descriptor 113, one or more EJB .class files 115, and any auxiliary resources required by the EJB application component 115. The class file contains the software code necessary to implement the operation of the EJB. The EJB deployment descriptor 113 describes the attributes of the EJB .class files and associated resources 115. Like the J2EE application deployment descriptors, the EJB deployment descriptor may also be encoded as an XML file. A J2EE application may contain any number of EJB .JAR files, and the three EJB.jar files 110, 111 and 112, shown in FIG. 1 are for illustration only and are not intended to be an upper nor a lower limit.
The J2EE application 107 may also contain J2EE client applications 120, 121 and 122. J2EE client applications perform functions on a user's computer and provide an interface to the J2EE Application. A J2EE application may contain any number of J2EE client application files, or alternatively, none at all. Like Enterprise Java™ Beans, these application components are also contained in .JAR files. As shown in the .JAR file 120 of FIG. 1, the J2EE client application is comprised of a J2EE client application 125, and a J2EE client application deployment descriptor 123. The J2EE client application 125 is comprised of one or more J2EE .class files, which contain the Java™ code implementing the functions of the J2EE client application. The J2EE client application 125 may also contain any auxiliary resources required by the J2EE client application. The J2EE client application deployment descriptor 123 details the attributes of the J2EE client application 125.
The J2EE application 107 also includes one or more web components. Web components are server-side objects used by the J2EE application to communicate with web-based clients. These objects process web-based user requests and generate static or dynamic content for the user in response. For example, web components allow a J2EE application to display customized web pages for each user.
Web components are contained in the .WAR files 130, 131 and 132. As shown in more detail in file 130, a .WAR file contains a web component 135 and a web component deployment descriptor 133. The web component deployment descriptor 133 is a .XML file describing the web component. Web component 135 consists of one or more types of web component files packaged together. Examples of web components include Java™ server page (.JSP) files, Java™ servlet .class file, hypertext markup language files (.HTML) files, or a graphics interchange format (.GIF) files.
Deploying a J2EE application requires several steps. First, the user must package each of the numerous application components, such as those disclosed in FIG. 1, into a .JAR file or a .WAR file. After packaging each application component into a separate file, the user must assemble the application component files into a single J2EE application (.EAR) file. Once the fully packaged J2EE application file has been created, the user installs the complete .EAR file onto the J2EE application server using a software application. This application requires the user to manually select the J2EE application to be deployed and the application server or servers on which to deploy the application.
The process of packaging application components into .JAR or .WAR files, and then into .EAR files can be very time-consuming. A large J2EE application may have over 500 different application components which need to be assembled in a .EAR file before deploying the application. If a software developer modifies even a single one of these application components, the entire process of packaging the .EAR file must be repeated. The packaging process can be wasteful with small applications as well. If a J2EE application contains only a single application component, this single application component is first packaged in a .JAR file. The resulting .JAR file is then further packaged in a .EAR file. This double packaging of a single application component wastes the software developer's time and provides no advantage in deploying the J2EE application.
Since deploying a J2EE application in a distributed computing environment involves a series of complicated packaging and distribution steps, the deployment of a new application is a difficult task for software administrators. The software administrator must use a separate software application to manually designate the application servers on which the application is to be deployed, and then manually initiate the deployment process. This process must be repeated whenever the software administrator wishes to deploy a revised or updated version of the application. Furthermore, the software administrator must manually undeploy the old application from the application server.
For software developers, the complicated application deployment process hinders software development. In software development, a developer may have to make frequent changes to the application source code. After each change, a developer must repeat the same arduous deployment process in order to test the application in development. This significantly increases the time and difficulty in developing a J2EE application.
Therefore, it is desirable to have a distributed computing environment which 1) automatically deploys new or updated applications to one or more computers in a distributed computing environment, 2) automatically undeploys unneeded or outdated applications or application components from one or more computers in a distributed computing environment, and 3) automatically deploys application components to one or more computers in a distributed computing environment without superfluous packaging steps.